home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 6122 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.4 KB  |  30 lines

  1. Newsgroups: comp.lang.c
  2. Path: Dortmund.Germany.EU.net!gellbo!wolfi
  3. From: wolfi@gellbo.gellrich-gmbh.de (Wolfgang Formann)
  4. Subject: Re: sscanf bug??????
  5. Message-ID: <06R9B8G@gellbo.gellrich-gmbh.de>
  6. Organization: Gellrich-GmbH
  7. References: <4fimvo$82s@fnord.dfw.net> <10FEB199622213548@erich.triumf.ca> <824160515snz@genesis.demon.co.uk> <4gh6uf$i2@mailhub.scitec.com.au>
  8. Date: Thu, 22 Feb 1996 19:56:41 GMT
  9.  
  10. In <4gh6uf$i2@mailhub.scitec.com.au> ramsesy@rd.scitec.com.au (Ramses Youhana) writes:
  11.  
  12. >You need the %ld for 16 bit processors or processors running in 16 bit mode.
  13. >Unfortunately, your stuck with this when using a PC (using 16 bit mode).
  14. >With 32 bit processors (such as a M68302 micro-controller) you don't need
  15. >the %ld.  %d will do as the processor treats the number as a 32 bit entity
  16. >anyway.  You have to be careful when saying that %ld and %d are interchangeable,
  17. >as a compiler for a 32 bit processor (such as the M68302) may not support the
  18. >"l" in the %ld format.
  19.  
  20. Well until DEC's Alpha was released I thought the same. I did not write the
  21. 'l' in '%ld'. But then I had to port some of my code to this 64-bit
  22. architecture. It was horrible!
  23.  
  24. So, if you plan to use your programs *ONLY* on 32-bit processors, then there
  25. is no need to write the 'l', but I am sure the 64-bitters will come sooner
  26. as we all do think and then the 'l' will be a *MUST*.
  27.  
  28. --
  29. Wolfgang Formann (wolfi@gellbo.gellrich-gmbh.de)
  30.